package conlon.seata02.dao;

import conlon.seata02.entity.AccountEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * <p>
 * 用户信息 Mapper 接口
 * </p>
 *
 * @author conlon
 * @since 2021-08-16
 */
@Mapper
public interface AccountDao extends BaseMapper<AccountEntity> {


    @Select("SELECT * FROM seata_account WHERE id = #{accountId} FOR UPDATE")
    AccountEntity getAccountById(@Param("accountId") Long accountId);
}